export const getProjectsList = (params) => {
  return http({
    method: "GET",
    url: `/projects/list`,
    params,
    prefix: "DESIGNER_URL",
  });
};

export const getProjecsInfo = (params) => {
  return http({
    method: "GET",
    url: `/projects/info`,
    params,
    prefix: "DESIGNER_URL",
  });
};

export const getProjectsAll = (params) => {
  return http({
    method: "GET",
    url: `/projects/all`,
    params,
    prefix: "DESIGNER_URL",
  });
};

export const createProjects = (data) => {
  return http({
    method: "post",
    url: `/projects/create`,
    data,
    prefix: "DESIGNER_URL",
  });
};

export const editProjects = (data) => {
  return http({
    method: "put",
    url: `/projects/edit`,
    data,
    prefix: "DESIGNER_URL",
  });
};

export const packageProjects = (data) => {
  return http({
    method: "put",
    url: `/projects/package/${data.id}`,
    prefix: "DESIGNER_URL",
  });
};

export const deleteProjects = (data) => {
  return http({
    method: "delete",
    url: `/projects/delete/${data._id}`,
    prefix: "DESIGNER_URL",
  });
};
